public class Sort2 {

        public static void main(String[] args) {
            int[] arr = new int[36];
            arr[0] = 1;
            arr[1] = 1;
            int sum = 0;
            for (int i = 0; i < arr.length; i++) {
                if (i > 2) {
                    arr[i] = arr[i - 1] + arr[i - 2];
                }
                sum += arr[i];
            }
            System.out.println("前36项和为：" + sum);
        }

}
